package com.zy.ipanalysis.dao;

import com.zy.ipanalysis.model.Ip;
import org.apache.ibatis.annotations.Param;

import java.util.HashMap;
import java.util.List;

/**
 * Created by ZYDR on 2015/12/26.
 */
public interface IpDao {
    public void insert(Ip ip);
    public Ip queryForId(@Param("id") int id);
    public List<Integer> queryForAll();
    public List<Integer> queryWithRange(@Param("startIndex") int startIndex,@Param("endIndex") int endIndex);
    public void updateIpTimesByVolume(@Param("ip_times") List<Ip> list);//批量修改出现次数
    public void updateIpInfo(@Param("ipId") int ipId, @Param("ispId") int ispId, @Param("districtId") int districtId);
    public void updateIspInfoByVolume(@Param("hashMap") HashMap<Integer,Integer> hashMap); //批量修改数据 // TODO: 2015/12/28  还没做
    public int getNumberByIspId(@Param("ispId") int ispId);
    public int count();
    public void insertByVolume(@Param("ipList") List<Ip> ipList);
    public int getFlowByIspId(@Param("ispId") int ispId);
}
